#include "log.h"
#include <string.h>
#include <stdarg.h>
#include <stdio.h>

#if LOG_DEBUG_LOG_EN > 0

bool m_logEnalne = TRUE;
static char m_logBuffer[LOG_BUFFER_MAX_SIZE];

void LogDebug(const char *format, ...)
{
    va_list args;
    int len;

    if(!m_logEnalne)
        return;

    va_start(args, format);

    len = vsprintf(m_logBuffer, format, args);

    m_logBuffer[len] = '\0';
    SOC_UartSend(SOC_LOG_UART_NO, m_logBuffer, len);
    va_end(args);
}

#endif 
